'''
Created on Jun 3, 2009

@license: License: LGPL
@copyright: (c) 2009, dogsing.cn
@author: ant-man(Bin Zhao)
'''

class StaticNum(object):
    """
    Construct a static number, tracing the current label number or temp var
    """
    def __init__(self, startn=1):
        self._static_num = startn

    def __call__(self):
        ret = self._static_num
        self._static_num += 1
        return ret
